﻿ #region Disclaimer/Info
 
 /////////////////////////////////////////////////////////////////////////////////////////////////
 //
 //   File:		ICombiner.cs
 //   Website:		http://dexterblogengine.com/
 //   Authors:		http://dexterblogengine.com/About.ashx
 //   Rev:		1
 //   Created:		19/01/2011
 //   Last edit:		19/01/2011
 //   License:		GNU Library General Public License (LGPL)
 // 
 //   For updated news and information please visit http://dexterblogengine.com/
 //   Dexter is hosted to Codeplex at http://dexterblogengine.codeplex.com
 //   For any question contact info@dexterblogengine.com
 //
 ///////////////////////////////////////////////////////////////////////////////////////////////////
 
 #endregion

using System;
using System.Collections.Generic;

namespace Dexter.Web.Mvc.ResourceCombiner {
	/// <summary>
	/// 	The contract for the concrete combier.
	/// </summary>
	public interface ICombiner {
		/// <summary>
		/// 	Clears all resourse added.
		/// </summary>
		void Clear ( );

		/// <summary>
		/// 	Clears all javascript resource added.
		/// </summary>
		void ClearAllJavascriptResource ( );

		/// <summary>
		/// 	Clears all stylesheet resource added.
		/// </summary>
		void ClearAllStylesheetResource ( );

		/// <summary>
		/// 	Adds the specified stylesheet to the combiner manager.
		/// </summary>
		/// <param name = "resource">The resource.</param>
		/// <exception cref = "ArgumentNullException"> If <paramref name = "resource" /> is <c>null</c> .</exception>
		void AddStylesheet ( string resource );

		/// <summary>
		/// 	Adds the specified javascript to the combiner manager.
		/// </summary>
		/// <param name = "resource">The resource.</param>
		/// <exception cref = "ArgumentNullException"> If <paramref name = "resource" /> is <c>null</c>.</exception>
		void AddJavascript ( string resource );

		/// <summary>
		/// 	Adds the specified stylesheets to the combiner manager.
		/// </summary>
		/// <param name = "resources">The source.</param>
		/// <exception cref = "ArgumentNullException"> If <paramref name = "resources" /> is <c>null</c>.</exception>
		void AddStylesheets ( IEnumerable <string> resources );

		/// <summary>
		/// 	Adds the specified javascripts to the combiner manager.
		/// </summary>
		/// <param name = "resources">The source.</param>
		/// <exception cref = "ArgumentNullException"> If <paramref name = "resources" /> is <c>null</c>.</exception>
		void AddJavascripts ( IEnumerable <string> resources );

		/// <summary>
		/// 	Renders all stylesheets not combined
		/// </summary>
		/// <example>
		/// 	<![CDATA[
		/// &lt;link type="text/css" rel="stylesheet" href="/site.css" /&gt;
		/// &lt;link type="text/css" rel="stylesheet" href="/site2.css" /&gt;
		/// ]]>
		/// </example>
		string RenderCssFiles ( );

		/// <summary>
		/// 	Renders all javascripts not combined
		/// </summary>
		/// <example>
		/// 	<![CDATA[
		/// &lt;script src="jquery-1.4.2.min.js" type="text/javascript" language="javascript"/&gt;&lt;/script/&gt;
		/// &lt;script src="effects.js" type="text/javascript" language="javascript"/&gt;&lt;/script/&gt;
		/// ]]>
		/// </example>
		string RenderJsFiles ( );

		/// <summary>
		/// 	Renders only one link to the combined resource
		/// </summary>
		/// <example>
		/// 	<![CDATA[
		/// &lt;link type="text/css" rel="stylesheet" href="/combines/css/123456" /&gt;
		/// ]]>
		/// </example>
		string RenderCssCombined ( );

		/// <summary>
		/// 	Renders only one link to the combined resource
		/// </summary>
		/// <example>
		/// 	<![CDATA[
		/// &lt;script src="combines/js/123456" type="text/javascript" language="javascript"/&gt;&lt;/script/&gt;
		/// ]]>
		/// </example>
		string RenderJsCombined ( );
	}
}
